package kr.saeildamil.androidstudy.ch06;

import kr.saeildamil.androidstudy.R;
import android.app.Activity;
import android.graphics.Color;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.EditText;
import android.widget.LinearLayout;

public class CodeLayOut extends Activity {
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.codelayout);
		
		
		final Button btn = (Button) findViewById(R.id.mybutton);
		btn.setOnClickListener(new OnClickListener() {
			public void onClick(View v) {
				btn.setTextSize(40);
			}
		});
		
		final LinearLayout layout = (LinearLayout) findViewById(R.id.mylinear);	
		layout.setOnClickListener(new OnClickListener() {
			public void onClick(View v) {
				layout.setOrientation(LinearLayout.HORIZONTAL);
			}		
		});
	
		EditText et = (EditText) findViewById(R.id.myedit);
		et.setBackgroundColor(Color.GREEN);
	}

}
